package com.bjpowernode.web;

import com.bjpowernode.entity.TDicValueDO;
import com.bjpowernode.result.R;
import com.bjpowernode.service.TDicValueService;
import jakarta.annotation.Resource;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 *
 */
@RestController
@Slf4j
@RequestMapping("/api/tDic")
public class TDicValueController {

    @Resource
    private TDicValueService tDicValueService;

    @GetMapping("{typeCode}")
    public R loadClueNoteWay(@PathVariable String typeCode) {
        log.info("要获取那个类型的所有数据 : {}" , typeCode);
        List<TDicValueDO> tDicValueDOList = tDicValueService.loadClueNoteWay(typeCode);
        return R.OK(tDicValueDOList);
    }
}
